<html>
<head><meta charset="utf-8"><title>Harmless tests with the triagebot · t-release/triagebot · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/index.html">t-release/triagebot</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html">Harmless tests with the triagebot</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="211771328"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771328" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771328">(Sep 30 2020 at 14:50)</a>:</h4>
<p>hi <span class="user-mention" data-user-id="255061">@LeSeulArtichaut</span> I'd like to take a stab at <a href="https://github.com/rust-lang/compiler-team-prioritization/issues/12">this issue</a>. I'm looking at the triagebot code.</p>
<p>My understanding is that each triagebot command needs a corresponding <code>./handlers/&lt;command&gt;.rs</code>. In order to probe how the triagebot works, I'd like to freely use it without raising concerns on Zulip or github <span aria-label="sweat smile" class="emoji emoji-1f605" role="img" title="sweat smile">:sweat_smile:</span> </p>
<p>is there some sort of a "staging" environment people can use to spam, debug etc.?</p>



<a name="211771498"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771498" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Léo Lanteri Thauvin <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771498">(Sep 30 2020 at 14:51)</a>:</h4>
<p>I don't think there is. (IIRC <span class="user-mention silent" data-user-id="116122">simulacrum</span> told me he does his testing "in production" directly here on Zulip)</p>



<a name="211771532"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771532" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771532">(Sep 30 2020 at 14:51)</a>:</h4>
<p>yeah that's basically the case today</p>



<a name="211771606"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771606" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771606">(Sep 30 2020 at 14:52)</a>:</h4>
<p>in theory it's not <em>too</em> hard to run locally but certainly not easy</p>



<a name="211771624"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771624" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771624">(Sep 30 2020 at 14:52)</a>:</h4>
<p>(you need to setup postgres and a webhook and stuff)</p>



<a name="211771676"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771676" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Léo Lanteri Thauvin <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771676">(Sep 30 2020 at 14:52)</a>:</h4>
<p>And you'd need an API key to connect to Zulip or something like that, I suppose?</p>



<a name="211771725"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771725" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771725">(Sep 30 2020 at 14:53)</a>:</h4>
<p>oh, yes, probably, from your own zulip instance likely</p>



<a name="211771881"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211771881" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Léo Lanteri Thauvin <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211771881">(Sep 30 2020 at 14:54)</a>:</h4>
<p><span class="user-mention silent" data-user-id="116122">simulacrum</span> <a href="#narrow/stream/224082-t-release.2Ftriagebot/topic/Harmless.20tests.20with.20the.20triagebot/near/211771725">said</a>:</p>
<blockquote>
<p>oh, yes, probably, from your own zulip instance likely</p>
</blockquote>
<p>Which IIRC is somewhat painful for certain environment, but I haven't read much or tried anything myself</p>



<a name="211772171"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211772171" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211772171">(Sep 30 2020 at 14:56)</a>:</h4>
<p>Zulip's zulip has a separate channel for bot testing.</p>



<a name="211772363"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211772363" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211772363">(Sep 30 2020 at 14:57)</a>:</h4>
<blockquote>
<p>Post here if you're testing Zulip functionality.</p>
</blockquote>
<p>Nope, only for zulip functionality.</p>



<a name="211775957"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211775957" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211775957">(Sep 30 2020 at 15:18)</a>:</h4>
<p>OK, so if I understand I can "spam" in a specific stream here and maybe target a dummy issue on the rust github issues tracker?</p>



<a name="211776556"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211776556" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211776556">(Sep 30 2020 at 15:22)</a>:</h4>
<p>and I'd need to run somewhere an instance of the triagebot for testing (which I can try to setup somewhere) but then I need someone to register (?) from this Zulip instance a token towards my testing triagebot instance.</p>



<a name="211776924"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211776924" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211776924">(Sep 30 2020 at 15:24)</a>:</h4>
<p>I think I'll take a step back and try to streamline a triagebot testing deployment, then we'll figure out the rest</p>



<a name="211777280"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211777280" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211777280">(Sep 30 2020 at 15:26)</a>:</h4>
<p><a href="https://github.com/rust-lang/triagebot/pull/810">Related PR</a></p>



<a name="211780377"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211780377" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211780377">(Sep 30 2020 at 15:47)</a>:</h4>
<p>fwiw I do not have problems with people proposing maybe-not-working PRs, deploying those, and then editing the code</p>



<a name="211781300"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211781300" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Léo Lanteri Thauvin <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211781300">(Sep 30 2020 at 15:53)</a>:</h4>
<p>Does landing a PR cause a downtime for both the GitHub and Zulip bots?</p>



<a name="211781412"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211781412" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211781412">(Sep 30 2020 at 15:54)</a>:</h4>
<p>no, or at least it shouldn't, unless we really break something</p>



<a name="211781432"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211781432" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211781432">(Sep 30 2020 at 15:54)</a>:</h4>
<p>but usually I can catch "really break" in review</p>



<a name="211781478"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211781478" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211781478">(Sep 30 2020 at 15:54)</a>:</h4>
<p>that said, if we have someone with bandwidth to work out a more streamlined local setup, then that would be great!</p>



<a name="211945375"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945375" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945375">(Oct 01 2020 at 17:30)</a>:</h4>
<p><span class="user-mention" data-user-id="116122">@simulacrum</span> So, I now have a full local installation of Zulip and the triagebot is listening on <code>localhost:8000</code> and uses a test github access token from my personal account.</p>
<ul>
<li>I have created a bot in Zulip (type: outgoing webhook) that point to my triagebot URL outside the Docker cointainer (e.g. <code>http://172.17.0.1:8000</code>)</li>
<li>I can send a message from Zulip to my triagebot, but I get an error message "Invalid JSON in response"<br>
<a href="/user_uploads/4715/p_vB_lEuWz-u8pedF2jBpgyv/2020-10-01_191608.png">2020-10-01_191608.png</a><div class="message_inline_image"><a href="/user_uploads/4715/p_vB_lEuWz-u8pedF2jBpgyv/2020-10-01_191608.png" title="2020-10-01_191608.png"><img src="/user_uploads/4715/p_vB_lEuWz-u8pedF2jBpgyv/2020-10-01_191608.png"></a></div></li>
</ul>



<a name="211945400"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945400" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945400">(Oct 01 2020 at 17:30)</a>:</h4>
<p>In the triagebot logs I see this request payload</p>
<div class="codehilite"><pre><span></span><code>[2020-10-01T17:29:09.089Z INFO  triagebot src/main.rs:12]
request_id=6a7c2c22-aebc-4069-a2e2-c408737bee2c request =
Request { method: POST, uri: /, version: HTTP/1.1, headers:
{&quot;host&quot;: &quot;172.17.0.1:8000&quot;, &quot;user-agent&quot;:
&quot;ZulipOutgoingWebhook/3.2&quot;, &quot;accept-encoding&quot;: &quot;gzip,
deflate&quot;, &quot;accept&quot;: &quot;*/*&quot;, &quot;connection&quot;: &quot;keep-alive&quot;, &quot;content-
type&quot;: &quot;application/json&quot;, &quot;content-length&quot;: &quot;780&quot;}, body:
Body(Streaming) }
</code></pre></div>



<a name="211945436"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945436" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945436">(Oct 01 2020 at 17:30)</a>:</h4>
<p>hm</p>



<a name="211945454"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945454" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945454">(Oct 01 2020 at 17:30)</a>:</h4>
<p>do you have your response logged somewhere?</p>



<a name="211945455"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945455" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945455">(Oct 01 2020 at 17:30)</a>:</h4>
<p>Do I need to configure anything else?</p>



<a name="211945479"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945479" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945479">(Oct 01 2020 at 17:30)</a>:</h4>
<p>that looks about right fwiw</p>



<a name="211945522"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945522" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945522">(Oct 01 2020 at 17:31)</a>:</h4>
<p>The triagebot answers with</p>
<div class="codehilite"><pre><span></span><code>[2020-10-01T17:29:09.090Z INFO  triagebot src/main.rs:206] request_id=6a7c2c22-
aebc-4069-a2e2-c408737bee2c response = Ok(Response { status: 200, version: HTTP/1.1,
headers: {&quot;x-request-id&quot;: &quot;6a7c2c22-aebc-4069-a2e2-c408737bee2c&quot;}, body:
Body(Full(b&quot;Triagebot is awaiting triage.&quot;)) })
</code></pre></div>



<a name="211945573"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211945573" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211945573">(Oct 01 2020 at 17:31)</a>:</h4>
<p>I think I need to form a correct JSON request and guess one recognized command <span aria-label="thinking" class="emoji emoji-1f914" role="img" title="thinking">:thinking:</span></p>



<a name="211955967"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211955967" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211955967">(Oct 01 2020 at 18:46)</a>:</h4>
<p>oh yeah, that makes sense then</p>



<a name="211956000"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/211956000" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#211956000">(Oct 01 2020 at 18:46)</a>:</h4>
<p>maybe the zulip hook is misconfigured? we should say unknown command Ithink</p>



<a name="212080825"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212080825" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212080825">(Oct 02 2020 at 14:22)</a>:</h4>
<p>Ok, I did another little step forward towards understanding how the triagebot works. Drafted a first version of what I see a possible "developer guide" for contributors<br>
<a href="https://github.com/apiraino/triagebot/blob/triagebot-docs-for-local-development/developer-setup.md">https://github.com/apiraino/triagebot/blob/triagebot-docs-for-local-development/developer-setup.md</a><br>
<span class="user-mention" data-user-id="116122">@simulacrum</span> I think the local setup, while not the easiset thing, with some instructions should become relatively clear.</p>
<p>What do you think of the general approach of this document?</p>



<a name="212080955"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212080955" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212080955">(Oct 02 2020 at 14:23)</a>:</h4>
<p>(clearly there are some "hand-wavy" things because I don't have an overview of the infra)</p>



<a name="212080966"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212080966" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Léo Lanteri Thauvin <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212080966">(Oct 02 2020 at 14:23)</a>:</h4>
<p>Thank you so much for writing this, it will surely be helpful for me :)</p>



<a name="212081148"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212081148" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212081148">(Oct 02 2020 at 14:25)</a>:</h4>
<p>this looks great!</p>



<a name="212081569"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212081569" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212081569">(Oct 02 2020 at 14:28)</a>:</h4>
<p>thanks! Now I have to context switch away from this and will be back in a couple of days, hopefully I can open a PR soon</p>



<a name="212081625"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/212081625" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#212081625">(Oct 02 2020 at 14:28)</a>:</h4>
<p>I need to figure out how the Zulip bot payload is prepared when the triagebot is called, I cannot yet replicate a hand-crafted cURL</p>



<a name="214110210"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110210" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110210">(Oct 21 2020 at 20:27)</a>:</h4>
<p><span class="user-mention" data-user-id="116122">@simulacrum</span> so, I gave a closer look at how the triagebot works and interact with zulip and github. Still some parts leave me a bit in the dark, so here's few questions.</p>



<a name="214110223"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110223" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110223">(Oct 21 2020 at 20:27)</a>:</h4>
<p>Let's say I want to implement <a href="https://github.com/rust-lang/compiler-team-prioritization/issues/12">issue 12</a>, a new command emitted from Zulip that reaches a specific issue on github and set labels.</p>



<a name="214110245"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110245" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110245">(Oct 21 2020 at 20:27)</a>:</h4>
<p>I've figured out the workflow to parse the Zulip command (in <a href="https://github.com/rust-lang/triagebot/blob/7489986e6ae8865bfa1580369aadfb7e319929b0/src/zulip.rs#L91">zulip.rs</a>), but don'thave clear how to forward it to github unless doing weird things that looks wrong.</p>



<a name="214110335"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110335" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110335">(Oct 21 2020 at 20:28)</a>:</h4>
<p>Do all commands from Zulip to Github need a specific file in <code>./handlers/&lt;cmd-name&gt;.rs</code>? Do I need to call Github from thre handler in <a href="http://zulip.rs">zulip.rs</a>?</p>



<a name="214110357"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110357" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110357">(Oct 21 2020 at 20:28)</a>:</h4>
<p>No, I would expect to just implement the behavior directly in <a href="http://zulip.rs">zulip.rs</a></p>



<a name="214110371"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110371" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110371">(Oct 21 2020 at 20:28)</a>:</h4>
<p>The handlers are specifically "we have received an event from github"</p>



<a name="214110482"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110482" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110482">(Oct 21 2020 at 20:29)</a>:</h4>
<p>ah ok that make sense <span aria-label="thumbs up" class="emoji emoji-1f44d" role="img" title="thumbs up">:thumbs_up:</span> then in this case I need to find my way to send a command to github (tried reusing some stuff around but it's not really a clean approach)</p>



<a name="214110620"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110620" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110620">(Oct 21 2020 at 20:30)</a>:</h4>
<p>I think I will post a draft/wip PR like you suggested days ago and then go from there (maybe with some hints)</p>



<a name="214110669"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110669" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110669">(Oct 21 2020 at 20:31)</a>:</h4>
<p>Yes, that would be the way to go. You should have access to a GithubClient which implements (some of) the API with nicer handlers</p>



<a name="214110775"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214110775" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214110775">(Oct 21 2020 at 20:32)</a>:</h4>
<p>ok, I will have a closer look - thank you!</p>



<a name="214117475"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214117475" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Noah Lev <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214117475">(Oct 21 2020 at 21:31)</a>:</h4>
<p><span class="user-mention silent" data-user-id="250987">apiraino</span> <a href="#narrow/stream/224082-t-release.2Ftriagebot/topic/Harmless.20tests.20with.20the.20triagebot/near/214110223">said</a>:</p>
<blockquote>
<p>Let's say I want to implement <a href="https://github.com/rust-lang/compiler-team-prioritization/issues/12">issue 12</a>, a new command emitted from Zulip that reaches a specific issue on github and set labels.</p>
</blockquote>
<p>By the way, you should be able to use <a href="https://github.com/rust-lang/compiler-team-prioritization/issues/12">rust-lang/compiler-team-prioritization#12</a> to autolink :)</p>



<a name="214125928"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/224082-t-release/triagebot/topic/Harmless%20tests%20with%20the%20triagebot/near/214125928" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> apiraino <a href="https://rust-lang.github.io/zulip_archive/stream/224082-t-release/triagebot/topic/Harmless.20tests.20with.20the.20triagebot.html#214125928">(Oct 21 2020 at 23:04)</a>:</h4>
<p>lol, thanks</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>